package com.cloud.basic.webservice;

//import org.apache.cxf.Bus;
//import org.apache.cxf.bus.spring.SpringBus;
//import org.apache.cxf.jaxws.EndpointImpl;
//import org.apache.cxf.transport.servlet.CXFServlet;
//import org.springframework.boot.web.servlet.ServletRegistrationBean;
//import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import javax.xml.ws.Endpoint;

/**
 * @program: basic
 * @description: 配置类
 * @author: Cloud
 * @create: 2021/10/19 11:03:02
 */
@Configuration
public class StartClas {

//    @Bean(name = Bus.DEFAULT_BUS_ID)
//    public SpringBus springBus(){
//        return new SpringBus();
//    }

//    @Bean(name = "wbsBean")
//    public ServletRegistrationBean dispactcherServlet(){
//        ServletRegistrationBean bean = new ServletRegistrationBean(new CXFServlet(), "/wbs/*");
//        return bean;
//    }

//    @Bean
//    public Endpoint endpointPurchase(SpringBus springBus, UserService userService) {
//        EndpointImpl endpoint = new EndpointImpl(springBus, userService);
//        endpoint.publish("/user-server");
//        System.out.println("服务发布成功！地址为：http://localhost:8080/wbs/user-server");
//        return endpoint;
//    }
}
